home *** CD-ROM | disk | FTP | other *** search
- 0 print"[147]":poke53280,0:poke53281,0:poke646,1
- 1 rem commodares problem #35-4:
- 2 rem bad luck
- 3 rem solution by
- 4 rem karen middaugh
- 5 rem
- 10 dim p(12) : for j=1 to 12 : read p(j):next
- 20 input"year: 19";y: input "month (1-12): ";m:input "day: ";d:if d>12 then 70
- 30 l=int((y+3)/4):da=6+y+l+p(m)+13: if int(y/4)=y/4 and m>2 then da=da+1
- 40 da=int((da/7-int(da/7))*7+.5)
- 50 if da=5 then print"the next friday the 13th is"m"/13/"y :end
- 60 d=13
- 70 m=m+1:if m>12 then m=1:y=y+1
- 80 goto 30
- 90 data 0,3,3,6,1,4,6,2,5,7,3,5
-